#include <iostream>

int main() {
    float A,B;
    scanf("%f",&A);
    scanf("%f",&B);
    float x;
    x=((A*3.5)+(B*7.5))/(3.5+7.5);
    printf("MEDIA=%.5lf",x);
    return 0;
}
